package cqrtplm.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.ty.basic.response.ResponseResult;
import cqrtplm.dto.DspfMbomBomDTO;
import cqrtplm.dto.RtCfgBomDTO;
import cqrtplm.dto.query.BomQueryDTO;
import cqrtplm.entity.DspfMbomDetailDO;
import cqrtplm.entity.RtCfgBomDO;
import cqrtplm.entity.RtCfgStatusInfoDO;
import org.springframework.web.multipart.MultipartFile;

import java.io.IOException;
import java.util.List;

/**
* @author 博
* @description 针对表【RT_CFG_BOM(配置管理-需求状态表-成品BOM表)】的数据库操作Service
* @createDate 2025-08-25 23:24:01
*/
public interface RtCfgBomService extends IService<RtCfgBomDO> {

//    ResponseResult getRtCfgBuildBOMDetail(Long oid,String statuscode) throws JsonProcessingException;

    void getRtCfgBuildBOMDetailVoid(RtCfgStatusInfoDO rtCfgStatusInfoDO) throws JsonProcessingException;

    ResponseResult getRtCfgBOMByPartNumber(BomQueryDTO dto);


    ResponseResult updateEbomPartNumberByPartNumber(DspfMbomDetailDO dspfMbomDetailDO);

    ResponseResult getRtCfgBuildBOMList(BomQueryDTO queryBomDTO);

    void buildBOM(List<DspfMbomDetailDO> list,String productCode,RtCfgStatusInfoDO rtCfgStatusInfoDO);

    void buildBOMV2(List<DspfMbomDetailDO> list,String productCode,RtCfgStatusInfoDO rtCfgStatusInfoDO);

    ResponseResult generateBOMToFactoryView(String partOid,String viewRefName,String viewDefOid);

    ResponseResult manualAdjustmentOfGroupPowerStructure(RtCfgBomDTO rtCfgBomDTO);

    ResponseResult getWorkFlowName(String templateName);

    ResponseResult replacePartNumber(String partNumber,String oid,String producttype);

    ResponseResult saveBOM(List<DspfMbomBomDTO> dto);

    ResponseResult importExcel(MultipartFile file,String bomid) throws Exception;

    ResponseResult getRtCfgBuildBOMZD(BomQueryDTO queryBomDTO);

    ResponseResult getRtCfgBOMByDrawing(BomQueryDTO dto);
}
